package com.atguigu.gulimall.product.service;

import com.atguigu.gulimall.product.vo.CategoryEntityVo;
import com.atguigu.gulimall.product.vo.Catelog2Vo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.product.entity.CategoryEntity;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author zzy
 * @email 510307801@qq.com
 * @date 2021-11-24 11:27:21
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);
    //递归挂载父子集菜单数据
    List<CategoryEntityVo> listWithtree();
    //(优化)分组挂载父子集菜单数据
    List<CategoryEntityVo> listWithtreeByGroup();

    void removeMenuByIds(List<Long> asList);
    //递归获取菜单全路径
    Long[] findCatelogPath(Long catelogId);

    void updateCascade(CategoryEntity category);

    List<CategoryEntity> getLevel1Categorys();

    Map<String, List<Catelog2Vo>> getCatalogJson();
}

